The disclosure relates to a method and an apparatus for generating digital sine wave signals. In particular, the systems disclosed and described relate to simplified systems for generating variable frequency sine wave signals for use in communications applications.
Many electronic applications and systems require the use of sinusoidal signal generators that may be digitally sampled. Often, such sinusoidal signal generators are used in communications applications, such as for use in mixing or tone generation. Further, other varied uses of sinusoidal signal generators exist.
Many electronic applications require that the frequency of the sinusoidal signal being generated is selectively variable. As depicted in FIG. 1, selectively variable frequency sinusoidal signals may be generated using a system such as system 10 that includes a look-up table 12 having a frequency input 14 to provide a waveform output 16. The frequency input provides a clock signal at the desired frequency and look-up table 12 is used to retrieve a memorized sample of the frequency associated sinusoid from a look-up table or data table. The data table may be stored on any type of storage device, commonly in a read only memory (ROM) stored table. Because it may be impractical to store sinusoid samples from a large number of frequencies, the frequency accuracy and distortion performance may be poor. Such performance may be improved by storing large amounts of samples, which translates into substantial amounts of chip real estate, that is used up by ROM.
Referring now to FIG. 2, a system for providing a sinusoidal waveform output 20 is depicted. System 20 includes a selective frequency input 22, a look-up table 24, an interpolation mechanism 26, and a waveform output 28. Similar to system 10, frequency input 22 supplies a clock signal to look-up table 24. Look-up table 24 retrieves stored samples of sinusoidal signals from a data table. The data table may be stored in any of a variety of storage devices, most commonly ROM. Because sample values at each clock tick of a desired frequency may not be available in the data table, an interpolation mechanism 26 interpolates sample values between points that are not included in the data table. Because, the look-up table requires numerous sample values and the interpolation mechanism requires a plurality of calculations, the complexity of system 20 is undesirable. Further, system 20 requires a set of sample values and derivative values in the data table for each of a plurality of frequencies.
Referring now to FIG. 3, a system 30 for generating a selective frequency sinusoidal signal is depicted. System 30 includes a selective frequency input 32, a recursive calculations device 34, and a waveform output 36. A selective frequency input is applied to the recursive calculations device. The recursive calculations device uses a pair of difference equations as its staring point, therefore some initial conditions must be input to the recursive calculations. Because system 30 does not use a look-up table, no ROM is required and therefore, may be seen as the smallest implementation in respect to die area (i.e. the area required on an integrated circuit device or other electronic device layout). However, recursive system 30 is very sensitive to initial conditions and requires calculations to be carried out with large numbers of decimal places, to provide appropriate accuracy. The algorithm complexity is usually far beyond an easy hardware implementation and typically requires a microprocessor or a digital signal processing (DSP) device including a floating point array. The recursive system 30 however is capable of providing accurate frequency setting and performance.
Accordingly, there is a need for an alternative method and apparatus for generating sinusoidal signals. There is a need for a method and apparatus for generating accurate sinusoidal signals in a wide frequency band that may be fit into a relatively small die area. Further, there is a need for a method and system for generating sinusoidal signals that may be used in communication systems and devices which maintain relatively good accuracy and require few and simple computations.
An exemplary embodiment relates to a signal generator. The signal generator includes a variable frequency selector. The variable frequency signal is configured to provide a variable frequency signal. The signal generator also includes a periodic signal generator. The periodic signal generator is configured to generate a periodic signal. The periodic signal generator has an input receiving the variable frequency selection and an output providing the periodic signal. The periodic signal has a frequency approximately the same as the variable frequency selection. The periodic signal generator is configured to store a table of derivative values associated with a reference periodic signal, each stored derivative value corresponding to a discrete time in the reference periodic signal. The periodic signal generator is configured to interpolate between the discrete points in the table of derivative values.
Another exemplary embodiment relates to a periodic signal generator. The periodic signal generator includes a programmable clock divider having a frequency select input and a master clock frequency input. The programmable clock divider has an output providing a clock frequency signal. The periodic signal generator also includes a periodic function generator. The periodic function generator has an input receiving the clock frequency signal, and the periodic function generator has an output providing a periodic function signal having a frequency substantially the same as the frequency of the clock frequency signal. The periodic function generator stores a data table of rate of change values associated with a reference periodic function. Each stored rate of change value corresponds to a discrete time in the reference periodic signal. The periodic function generator is configured to interpolate between the discrete points in the data table.
Yet another exemplary embodiment relates to a method of generating a periodic signal having a selectively variable frequency. The method includes receiving a frequency select signal by a variable frequency clock. The method also includes receiving a master clock signal by the variable frequency clock. Further, the method includes providing a selected frequency signal by the variable frequency clock, to a periodic function generator configured to generate a periodic signal of variable frequency. Further still, the method includes retrieving a rate of change value from a stored data table of rate of change values associated with the periodic signal. Yet further still, the method includes calculating a new value of the periodic signal using an interpolation based on the retrieved rate of change value from the data table of values.